package com.sbr.esbmonitor.tests.builders;

import java.util.HashMap;
import java.util.Map;

import com.sbr.esbmonitor.camel.model.Endpoint;


public class EndpointBuilder {

	private String componentName;
	private String name;
	private Map<String, String> parameters = new HashMap<String, String>();

	
	public EndpointBuilder() {
	}
	
	public EndpointBuilder name(String name) {
		this.name = name;
		return this;
	}
	
	public EndpointBuilder componentName(String componentName) {
		this.componentName = componentName;
		return this;
	}
	
	public EndpointBuilder withParameter(String key, String value) {
		this.parameters.put(key, value);
		return this;
	}

	public Endpoint build() {
		return new Endpoint(componentName, name, parameters);
	}
}
